From 080c8f3be530922f711dd2b2544cb3fce743c35d Mon Sep 17 00:00:00 2001 From: =?utf8?q?IOhannes=20m=20zm=C3=B6lnig?= Date: Thu, 21 Jan 2016 21:22:41 +0100 Subject: [PATCH] install target --- debian/libbuilder/Makefile | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/debian/libbuilder/Makefile b/debian/libbuilder/Makefile index fab6cb74..bc490fa8 100644 --- a/debian/libbuilder/Makefile +++ b/debian/libbuilder/Makefile @@ -1,12 +1,15 @@ -# Automatically generated makefile, created by the Introjucer -# Don't edit this file! Your changes will be overwritten when you re-save the Introjucer project! +# build a dynamic library for juce +prefix = /usr/local +libdir = $(prefix)/lib +includedir = $(prefix)/include # (this disables dependency generation if multiple architectures are set) DEPFLAGS := $(if $(word 2, $(TARGET_ARCH)), , -MMD) empty= -MODULES_PATH=../../modules +JUCE_PATH=../.. +MODULES_PATH=$(JUCE_PATH)/modules SOURCES=juce_audio_basics.cpp \ juce_audio_devices.cpp \ @@ -102,7 +105,7 @@ TARGET := libjuce.so OBJECTS=$(SOURCES:%.cpp=$(OBJDIR)/%.o) -.PHONY: clean install test +.PHONY: clean install install-lib install-headers test $(OUTDIR)/$(TARGET): $(OBJECTS) $(RESOURCES) @echo Linking juce_dll @@ -117,6 +120,18 @@ clean: @echo Cleaning juce_dll rm -rf build +install-lib: $(OUTDIR)/$(TARGET) + @echo Installing juce_dll + install -d $(DESTDIR)$(libdir) + install -m664 $^ $(DESTDIR)$(libdir)/libjuce.so +install-headers: + @echo Installing juce_dll + install -d $(DESTDIR)$(includedir)/juce + cd $(JUCE_PATH) && find modules/ -type f -name "juce_*.h" -exec cp --parent {} $(DESTDIR)$(includedir)/juce \; + cd $(JUCE_PATH) && find modules/juce_box2d/box2d/ -type f -name "*.h" -exec cp --parent {} $(DESTDIR)$(includedir)/juce \; + +install: install-headers install-lib + -include $(OBJECTS:%.o=%.d) test: -- 2.30.2